package action;

import manager.ComManager;
import manager.ObjectFactory;
import bean.ConnectionMessage;
import bean.UserBean;

public class ActionConnection {
	public UserBean  doConnection(UserBean u){
		ObjectFactory of = new ObjectFactory();
		ComManager com = of.createComManager();
		ConnectionMessage mOut = of.createConnectionMessage();
		ConnectionMessage mIn ;
		mOut.setUser(u);
		mIn = (ConnectionMessage)com.sendMessage(mOut);	
		return mIn.getUser();
	}
	
}
